<!-- BEGIN PAGE CONTENT-->
<!-- BEGIN DASHBOARD STATS -->
<style>
    .label{
        margin-bottom: 10px;
    }
    .num-div{
        margin-top: 15px !important;
    }
    h4{
        font-size: 15px !important;
    }
    .week-order, .month-order{
        display: none;
    }
</style>
<div class="row">
    <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
        <div class="dashboard-stat blue-madison">
            <div class="visual">
                <i class="fa fa-comments"></i>
            </div>
            <div class="details">
                <div class="number">
                    <?= $info['total']->num ?>
                </div>
                <div class="desc">
                    总订单量
                </div>
            </div>
            <a class="more" href="javascript:;">
                老徐租车 <i class="fa fa-motorcycle"></i>
            </a>
        </div>
    </div>
    <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
        <div class="dashboard-stat red-intense">
            <div class="visual">
                <i class="fa fa-bar-chart-o"></i>
            </div>
            <div class="details">
                <div class="number">
                    ￥<?= $info['total']->amount ?>
                </div>
                <div class="desc">
                    总订单金额
                </div>
            </div>
            <a class="more" href="javascript:;">
                老徐租车 <i class="fa fa-motorcycle"></i>
            </a>
        </div>
    </div>
    <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
        <div class="dashboard-stat green-haze">
            <div class="visual">
                <i class="fa fa-shopping-cart"></i>
            </div>
            <div class="details">
                <div class="number">
                    ￥<?= $info['total']->payed_amount ?>
                </div>
                <div class="desc">
                    已支付订单金额
                </div>
            </div>
            <a class="more" href="javascript:;">
                老徐租车 <i class="fa fa-motorcycle"></i>
            </a>
        </div>
    </div>
    <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
        <div class="dashboard-stat purple-plum">
            <div class="visual">
                <i class="fa fa-globe"></i>
            </div>
            <div class="details">
                <div class="number">
                    ￥<?= $info['total_promise'] ?>
                </div>
                <div class="desc">
                    保证金金额池
                </div>
            </div>
            <a class="more" href="javascript:;">
                老徐租车 <i class="fa fa-motorcycle"></i>
            </a>
        </div>
    </div>
</div>
<!-- END DASHBOARD STATS -->
<div class="clearfix">
</div>
<div class="row">
    <div class="col-md-6 col-sm-6">
        <!-- BEGIN PORTLET-->
        <div class="portlet light ">
            <div class="portlet-title">
                <div class="caption">
                    <i class="icon-bar-chart font-green-sharp hide"></i>
                    <span class="caption-subject font-green-sharp bold uppercase">用户订单</span>
                    <span class="caption-helper">本周/本月</span>
                </div>
                <div class="actions">
                    <div class="btn-group btn-group-devided" data-toggle="buttons">
                        <label class="btn btn-transparent grey-salsa btn-circle btn-sm active" id="option1">
                            <input type="radio" name="options" class="toggle" >本周</label>
                        <label class="btn btn-transparent grey-salsa btn-circle btn-sm" id="option2">
                            <input type="radio" name="options" class="toggle">本月</label>
                    </div>
                </div>
            </div>
            <div class="portlet-body">
                <div style="margin: 20px 0 10px 30px;text-align: center">
                    <div class="row week-order">
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <label class="label label-sm label-success">总订单量</label>
                            <h4 class="num-div"><?= $info['total_week']->num ?>单（￥<?= $info['total_week']->amount ?>）</h4>
                        </div>
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <span class="label label-sm label-info">进行中</span>
                            <h4 class="num-div"><?= $info['total_week']->ing_num ?>单（￥<?= $info['total_week']->ing_amount ?>）</h4>
                        </div>
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <span class="label label-sm label-danger">待支付</span>
                            <h4 class="num-div"><?= $info['total_week']->wait_num ?>单（￥<?= $info['total_week']->wait_amount ?>）</h4>
                        </div>
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <span class="label label-sm label-warning">已完成</span>
                            <h4 class="num-div"><?= $info['total_week']->payed_num ?>单（￥<?= $info['total_week']->payed_amount ?>）</h4>
                        </div>
                    </div>
                    <div class="row month-order">
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <label class="label label-sm label-success">总订单量</label>
                            <h4 class="num-div"><?= $info['total_month']->num ?>单（￥<?= $info['total_month']->amount ?>）</h4>
                        </div>
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <span class="label label-sm label-info">进行中</span>
                            <h4 class="num-div"><?= $info['total_month']->ing_num ?>单（￥<?= $info['total_month']->ing_amount ?>）</h4>
                        </div>
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <span class="label label-sm label-danger">待支付</span>
                            <h4 class="num-div"><?= $info['total_month']->wait_num ?>单（￥<?= $info['total_month']->wait_amount ?>）</h4>
                        </div>
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <span class="label label-sm label-warning">已完成</span>
                            <h4 class="num-div"><?= $info['total_month']->payed_num ?>单（￥<?= $info['total_month']->payed_amount ?>）</h4>
                        </div>
                    </div>
                </div>
            </div>
            <script>
                $(document).ready(function () {
                    $(".week-order").show();
                    $(".month-order").hide();
                });
                $("#option1").click(function () {
                    $(".week-order").show();
                    $(".month-order").hide();
                })
                $("#option2").click(function () {
                    $(".week-order").hide();
                    $(".month-order").show();
                })
            </script>
        </div>
        <!-- END PORTLET-->
    </div>
    <div class="col-md-6 col-sm-6">
        <!-- BEGIN PORTLET-->
        <div class="portlet light ">
            <div class="portlet-title">
                <div class="caption">
                    <i class="icon-bar-chart font-green-sharp hide"></i>
                    <span class="caption-subject font-green-sharp bold uppercase">用户量</span>
                </div>
            </div>
            <div class="portlet-body">
                <div style="margin: 20px 0 10px 30px;text-align: center">
                    <div class="row">
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <label class="label label-sm label-success">总用户量</label>
                            <h4 class="num-div"><?= $info['user']->total ?></h4>
                        </div>
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <span class="label label-sm label-info">昨日新增</span>
                            <h4 class="num-div"><?= $info['user']->yesterday ?></h4>
                        </div>
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <span class="label label-sm label-danger">本周新增</span>
                            <h4 class="num-div"><?= $info['user']->week ?></h4>
                        </div>
                        <div class="col-md-3 col-sm-3 col-xs-6 text-stat">
                            <span class="label label-sm label-warning">本月新增</span>
                            <h4 class="num-div"><?= $info['user']->month ?></h4>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <!-- END PORTLET-->
    </div>
</div>
<div class="clearfix">
</div>
<div class="row">
    <div class="col-md-6 col-sm-6">
        <!-- BEGIN PORTLET-->
        <div class="portlet light bordered">
            <div class="portlet-title tabbable-line">
                <div class="caption">
                    <span class="caption-subject font-blue-sharp ">最近订单</span>
                </div>
            </div>
            <div class="portlet-body">
                <!--BEGIN TABS-->
                <div class="tab-content">
                    <div class="tab-pane active" id="tab_1_1">
                        <div class="scroller" style="height: 337px;" data-always-visible="1" data-rail-visible="0">
                            <ul class="feeds">
                                <?php foreach ($info['order'] as $v): ?>
                                    <li style="display: flex;justify-content: flex-start;align-items: center;">
                                        <div style="width: 70%" class="cont">
                                            <div class="cont-col2">
                                                <img style="width: 50px;height: auto;border-radius: 50%;" src="<?= $v->avatar ?>" alt="">
                                                <span><?= $v->nick_name ?></span>
                                                <div class="desc" style="display:inline;margin-left: 5px;">
                                                    <?= IOSS_StaticConfig::Sec2Time(time() - $v->create_time) ?>前租用了车辆 - 《<?= $v->name ?>》：
                                                    <?php if ($v->status == 0): ?>
                                                        <span class="label label-sm label-default">
                                                            骑行中...
                                                        </span>
                                                    <?php elseif ($v->status == 1): ?>
                                                        <label class="label label-sm label-warning">
                                                            还车确认中...
                                                        </label>
                                                    <?php elseif ($v->status == 2 && $v->pay_status == 0): ?>
                                                        <label class="label label-sm label-danger">
                                                            待付款...
                                                        </label>
                                                    <?php elseif ($v->status == 2 && $v->pay_status == 1): ?>
                                                        <label class="label label-sm label-success">
                                                            已支付...
                                                        </label>
                                                    <?php endif; ?>
                                                </div>
                                            </div>
                                        </div>
                                        <div style="width: 30%;text-align: right" class="date">
                                            <?= date('Y-m-d H:i',$v->create_time) ?>
                                        </div>
                                    </li>
                                <?php endforeach; ?>
                            </ul>
                        </div>
                    </div>
                </div>
                <!--END TABS-->
            </div>
        </div>
        <!-- END PORTLET-->
    </div>
    <div class="col-md-6 col-sm-6">
        <!-- BEGIN PORTLET-->
        <div class="portlet light bordered">
            <div class="portlet-title tabbable-line">
                <div class="caption">
                    <span class="caption-subject font-green-sharp ">近期保证金缴纳</span>
                </div>
            </div>
            <div class="portlet-body">
                <!--BEGIN TABS-->
                <div class="tab-content">
                    <div class="tab-pane active" id="tab_1_1">
                        <div class="scroller" style="height: 337px;" data-always-visible="1" data-rail-visible="0">
                            <ul class="feeds">
                                <?php foreach ($info['promise'] as $v): ?>
                                    <li style="display: flex;justify-content: flex-start;align-items: center;">
                                        <div style="width: 70%" class="cont">
                                            <div class="cont-col2">
                                                <img style="width: 50px;height: auto;border-radius: 50%;" src="<?= $v->avatar ?>" alt="">
                                                <span><?= $v->nick_name ?></span>
                                                <div class="desc" style="display:inline;margin-left: 5px;">
                                                    <?= IOSS_StaticConfig::Sec2Time(time() - $v->pay_time) ?>前缴纳了保证金 - ￥<?= $v->amount ?>
                                                </div>
                                            </div>
                                        </div>
                                        <div style="width: 30%;text-align: right" class="date">
                                            <?= date('Y-m-d H:i',$v->pay_time) ?>
                                        </div>
                                    </li>
                                <?php endforeach; ?>
                            </ul>
                        </div>
                    </div>
                </div>
                <!--END TABS-->
            </div>
        </div>
        <!-- END PORTLET-->
    </div>
</div>


<!-- END PAGE CONTENT-->
